<template>
  <div id="xiangQing">
    <van-swipe class="my-swipe" :autoplay="3000" indicator-color="white">
      <van-swipe-item v-for="(item,index) in data.designPictureList" :key="index"><img :src="baseUrl11+item.id"></van-swipe-item>
    </van-swipe>
    <p class="name">
      {{data.villageName}}
    </p>
    <p class="ssq">
      <span class="lf">所属区域</span>
      <span class="rg">{{data.cityName}}</span>
    </p>
    <p class="type">
      {{data.keyWord}}
    </p>
    <div class="text" v-html="data.mainContent"></div>
  </div>
</template>
<script>
export default {
  name: 'xiangQing',
  data () {
    return {
      imgData: [],
      baseUrl11: window.g.OSSPriviewId,
      data: {

      },
    };
  },

  mounted: async function () {
    if (ZWJSBridge) {
      ZWJSBridge.setTitle({
        "title": "农村风貌"
      }).then(res => {
      }).catch(err => {
      })
    }
    this.data = JSON.parse(this.$route.query.data)
  }
}
</script>
<style lang="scss" scoped>
#xiangQing {
  width: 100vw;
  height: 100vh;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  line-height: 30px;
  padding: 10px 20px;
  color: #1a1a1a;
  img {
    height: 180px;
    width: 100%;
  }
  .name {
    font-size: 24px;
    font-family: "Helvetica Neue", Helvetica, STHeiTi, sans-serif;
    font-weight: bold;
    margin-bottom: 10px;
  }
  .type {
    padding: 0px 10px;
    background: #f8f8f8;
    border-radius: 2px;
    display: inline-block;
    margin-bottom: 10px;
  }
  .my-swipe {
    margin-bottom: 10px;
  }
  .ssq {
    margin-bottom: 10px;
    .lf {
      color: #5d5d5d;
    }
    .rg {
      margin-left: 10px;
    }
  }
  .text {
    p,
    span {
      text-indent: 2em !important;
      text-align: justify !important;
      text-justify: inter-ideograph !important;
    }
  }

  //   img {
  //     display: block;
  //     margin: 0 auto;
  //     width: auto;
  //     height: 130px;
  //     margin-bottom: 10px;
  //   }
}
</style>